<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <title>dssictls</title>
    <link rel="stylesheet" type="text/css" href="csound.css" />
    <meta name="generator" content="DocBook XSL Stylesheets V1.78.1" />
    <link rel="home" href="index.html" title="The Canonical Csound Reference Manual" />
    <link rel="up" href="OpcodesTop.html" title="Orchestra Opcodes and Operators" />
    <link rel="prev" href="dssiaudio.html" title="dssiaudio" />
    <link rel="next" href="dssiinit.html" title="dssiinit" />
  </head>
  <body>
    <div class="navheader">
      <table width="100%" summary="Navigation header">
        <tr>
          <th colspan="3" align="center">dssictls</th>
        </tr>
        <tr>
          <td width="20%" align="left"><a accesskey="p" href="dssiaudio.html">Prev</a> </td>
          <th width="60%" align="center">Orchestra Opcodes and Operators</th>
          <td width="20%" align="right"> <a accesskey="n" href="dssiinit.html">Next</a></td>
        </tr>
      </table>
      <hr />
    </div>
    <div class="refentry">
      <a id="dssictls"></a>
      <div class="titlepage"></div>
      <a id="IndexDssictls" class="indexterm"></a>
      <div class="refnamediv">
        <h2>
          <span class="refentrytitle">dssictls</span>
        </h2>
        <p>dssictls — Send control information to a LADSPA or DSSI plugin.
    </p>
      </div>
      <div class="refsect1">
        <a id="idp100017376"></a>
        <h2>Syntax</h2>
        <pre class="synopsis"><span class="command"><strong>dssictls</strong></span> ihandle, iport, kvalue, ktrigger </pre>
      </div>
      <div class="refsect1">
        <a id="idp100019440"></a>
        <h2>Description</h2>
        <p><span class="emphasis"><em>dssictls</em></span> sends control values to a plugin's control port</p>
      </div>
      <div class="refsect1">
        <a id="idp100083104"></a>
        <h2>Initialization</h2>
        <p>
      <span class="emphasis"><em>ihandle</em></span>  - handle for the plugin returned by <a class="link" href="dssiinit.html" title="dssiinit"><em class="citetitle">dssiinit</em></a>
    </p>
        <p>
      <span class="emphasis"><em>iport</em></span>  - control port number
    </p>
      </div>
      <div class="refsect1">
        <a id="idp100086528"></a>
        <h2>Performance</h2>
        <p>
      <span class="emphasis"><em>kvalue</em></span> - value to be assigned to the port
    </p>
        <p>
      <span class="emphasis"><em>ktrigger</em></span> - determines whether the control information will be sent (ktrigger = 1) or not. This is useful for thinning control information, generating ktrigger with <a class="link" href="metro.html" title="metro"><em class="citetitle">metro</em></a>
    </p>
        <p>
      <span class="emphasis"><em>dssictls</em></span> sends control information to a LADSPA or DSSI plugin's control port. The valid control ports and ranges are given by <a class="link" href="dssiinit.html" title="dssiinit"><em class="citetitle">dssiinit</em></a> . Using values outside the ranges may produce unspecified behaviour.
    </p>
      </div>
      <div class="refsect1">
        <a id="idp100092160"></a>
        <h2>Examples</h2>
        <p>
      Here is an example of the dssictls opcode. It uses the file <a class="ulink" href="examples/dssictls.csd" target="_top"><em class="citetitle">dssictls.csd</em></a>.
            </p>
        <div class="example">
          <a id="idp100094016"></a>
          <p class="title">
            <strong>Example 207. Example of the dssictls opcode.</strong>
          </p>
          <div class="example-contents">
            <p>See the sections <a class="link" href="UsingRealTime.html" title="Real-Time Audio"><em class="citetitle">Real-time Audio</em></a> and <a class="link" href="CommandFlags.html" title="Csound command line"><em class="citetitle">Command Line Flags</em></a> for more information on using command line flags.</p>
            <pre class="programlisting">
<span class="csdtag">&lt;CsoundSynthesizer&gt;</span>
<span class="csdtag">&lt;CsOptions&gt;</span>
<span class="comment">; Select audio/midi flags here according to platform</span>
-odac     <span class="comment">;;;RT audio out</span>
<span class="comment">;-iadc    ;;;uncomment -iadc if RT audio input is needed too</span>
<span class="comment">; For Non-realtime ouput leave only the line below:</span>
<span class="comment">; -o dssictls.wav -W ;;; for file output any platform</span>
<span class="csdtag">&lt;/CsOptions&gt;</span>
<span class="csdtag">&lt;CsInstruments&gt;</span>

<span class="ohdr">sr</span> <span class="op">=</span> 44100
<span class="ohdr">ksmps</span> <span class="op">=</span> 32
<span class="ohdr">nchnls</span> <span class="op">=</span> 2

gihandle dssiinit "caps.so", 1, 1	<span class="comment">; = equaliser and</span>
gaoutl <span class="opc">init</span>  0				<span class="comment">; verbose about all ports</span>
gaoutr <span class="opc">init</span>  0

<span class="oblock">instr</span> 1	<span class="comment">; activate DSSI</span>

dssiactivate gihandle, 1
<span class="oblock">endin</span>

<span class="oblock">instr</span> 2
ain1	<span class="opc">diskin2</span> "beats.wav", 1,0,1	<span class="comment">; loop</span>

gaoutl <span class="op">=</span> gaoutl<span class="op">+</span>(ain1<span class="op">*</span>.1)		<span class="comment">; temper input</span>
gaoutr <span class="op">=</span> gaoutr<span class="op">+</span>(ain1<span class="op">*</span>.1)
<span class="oblock">endin</span>

<span class="oblock">instr</span> 3

dssictls gihandle, 2, <span class="op">-</span>48, 1	<span class="comment">; 31 Hz range -48 to 24</span>
dssictls gihandle, 3, <span class="op">-</span>48, 1	<span class="comment">; 63 Hz range -48 to 24</span>
dssictls gihandle, 4, <span class="op">-</span>48, 1	<span class="comment">; 125 Hz range -48 to 24</span>
dssictls gihandle, 5, 20, 1	<span class="comment">; 250 Hz range -48 to 24</span>
dssictls gihandle, 6, <span class="op">-</span>48, 1	<span class="comment">; 500 Hz range -48 to 24</span>
dssictls gihandle, 7, <span class="op">-</span>48, 1	<span class="comment">; 1 kHz Hz range -48 to 24</span>
dssictls gihandle, 8, <span class="op">-</span>48, 1	<span class="comment">; 2 kHz range -48 to 24</span>
dssictls gihandle, 9, 24, 1	<span class="comment">; 4 kHz range -48 to 24</span>
dssictls gihandle, 10, 24, 1	<span class="comment">; 8 kHz range -48 to 24</span>
dssictls gihandle, 11, 24, 1	<span class="comment">; 16 kHz range -48 to 24</span>

<span class="oblock">endin</span>

<span class="oblock">instr</span> 4

aout1, aout2	dssiaudio gihandle, gaoutl, gaoutr	<span class="comment">;get beats.wav, mono out</span>
		<span class="opc">outs</span> aout1,aout2

gaoutl <span class="op">=</span> 0
gaoutr <span class="op">=</span> 0
<span class="oblock">endin</span>

<span class="csdtag">&lt;/CsInstruments&gt;</span>
<span class="csdtag">&lt;CsScore&gt;</span>
<span class="stamnt">i</span> 1 0 20 
<span class="stamnt">i</span> 2 1 20
<span class="stamnt">i</span> 3 1 20
<span class="stamnt">i</span> 4 0 20

<span class="stamnt">e</span>
<span class="csdtag">&lt;/CsScore&gt;</span>
<span class="csdtag">&lt;/CsoundSynthesizer&gt;</span>
</pre>
          </div>
        </div>
        <p><br class="example-break" />
    </p>
      </div>
      <div class="refsect1">
        <a id="idp100098304"></a>
        <h2>Credits</h2>
        <p>2005</p>
        <p>By: Andrés Cabrera</p>
        <p>Uses code from Richard Furse's LADSPA sdk.</p>
      </div>
    </div>
    <div class="navfooter">
      <hr />
      <table width="100%" summary="Navigation footer">
        <tr>
          <td width="40%" align="left"><a accesskey="p" href="dssiaudio.html">Prev</a> </td>
          <td width="20%" align="center">
            <a accesskey="u" href="OpcodesTop.html">Up</a>
          </td>
          <td width="40%" align="right"> <a accesskey="n" href="dssiinit.html">Next</a></td>
        </tr>
        <tr>
          <td width="40%" align="left" valign="top">dssiaudio </td>
          <td width="20%" align="center">
            <a accesskey="h" href="index.html">Home</a>
          </td>
          <td width="40%" align="right" valign="top"> dssiinit</td>
        </tr>
      </table>
    </div>
  </body>
</html>
